package ${package}.${moduleName}.domain.convert.support;

import com.dido.feign.convertor.Convertor;
import ${package}.${moduleName}.domain.convert.${BeanName}Convert;
import ${package}.${moduleName}.domain.entity.${BeanName};
import ${package}.${moduleName}.domain.vo.${BeanName}VO;
import org.springframework.stereotype.Component;
import java.util.List;

/**
* ${BeanName} springbean entity vo 转换器
* 需要${BeanName}Convert 转换器配合
*
* @author ${author} ${email}
* @since ${version} ${date}
*/
@Component
public class ${BeanName}Convertor implements Convertor<${BeanName}, ${BeanName}VO> {
    @Override
    public ${BeanName} from(${BeanName}VO vo) {
        return ${BeanName}Convert.INSTANCE.convert(vo);
    }

    @Override
    public ${BeanName}VO to(${BeanName} entity) {
        return ${BeanName}Convert.INSTANCE.convert(entity);
    }

    @Override
    public List<${BeanName}VO> toList(List<${BeanName}> list) {
        return ${BeanName}Convert.INSTANCE.convertList(list);
    }
}
